Skip to content

Support SETUPPY_FORCE_PURE in tests #79

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 17, 2025
Merged

Conversation

mgorny
Copy link
Contributor

@mgorny mgorny commented Dec 15, 2023

Support testing without the C extension if SETUPPY_FORCE_PURE is set. This makes the test suite behavior consistent with setup.py behavior.

Support testing without the C extension if SETUPPY_FORCE_PURE is set.
This makes the test suite behavior consistent with setup.py behavior.
@mgorny
Copy link
Contributor Author

mgorny commented Apr 17, 2025

Ping.

@ionelmc
Copy link
Owner

ionelmc commented Apr 17, 2025

@mgorny Ooops I missed this. Why do I need this? AFAIK there's no place where I set SETUPPY_FORCE_PURE for tests.

@mgorny
Copy link
Contributor Author

mgorny commented Apr 17, 2025

Downstreams use SETUPPY_FORCE_PURE to build pure Python version of the package, and then the test suite fails.

@ionelmc
Copy link
Owner

ionelmc commented Apr 17, 2025

I just want to understand why anyone would repackage this as pure-python in a downstream. Which distros? Some details?

@mgorny
Copy link
Contributor Author

mgorny commented Apr 17, 2025

Gentoo. We give our users an option to disable all C extensions, if they wish. However, in my case the primary use is comparing behavior of the same module on PyPy (where there is no C extension ever) and CPython. By building the package on CPython without the extension modules, I have fewer differences to be concerned about, and therefore it is easier to determine whether the particular problem is specific to PyPy or perhaps to the use of pure Python code paths.

@ionelmc ionelmc merged commit 58a13f3 into ionelmc:master Apr 17, 2025
@mgorny
Copy link
Contributor Author

mgorny commented Apr 18, 2025

Thank you!

@mgorny mgorny deleted the pure-test branch April 18, 2025 02:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants